<?php
$tag_attrs=$object->tags($item['id']);
$tag_attrs=is_array($tag_attrs)?$tag_attrs:array();
$xx=implode(',',$tag_attrs);

$tag_words=$object->wordtags($item['id'],$item['level_id']);
$tag_words=is_array($tag_words)?$tag_words:array();

$tag_single_arr=$object->wwwww($item['id']);
$yy=implode(',',$tag_single_arr);
?>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title><?php echo $item['title'];?>_<?php echo $item['level_id'];?>级英语阅读_<?php echo $xx;?>_英语分级阅读</title>
<meta name="keywords" content="<?php echo $item['level_id'];?>级英语阅读,<?php echo $xx;?>,<?php echo $yy;?>" />
<meta name="description" content="<?php echo $item['description'];?>" />
<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=0, width=device-width">
<link href="http://read.qsbdc.com/mobile/static/css/touch.css" rel="stylesheet" type="text/css" />
<?php
loadjs(array('common','jquery','qsbdcplayer','jquery.colorbox','mypaper','user'),P_JS);
loadcss(array('colorbox'),P_CSS);
loadcss(array('main'));
loadjs(array('main'));
?>
<script>
$(document).ready(function(){
	if(flashdetect.f){
		insertaudio('','qsplayer_1','/common/static/js/');
	}
});
</script>
</head>
<body>
<?php include(dirname(dirname(__FILE__)).'/header.inc.php');?>

<div id="nav1">当前位置：<a href="/mobile.php">首页</a> -> <a href="<?php echo url('arc','mylist',"level_id={$item['level_id']}");?>"><?php echo $item['level_id'];?>级英语阅读</a> -> 文章列表</div> 

<div class="arc_content">
<h1 class="h1title"><?php echo $item['title'];?></h1>
<p style="text-align:center; padding:5px 0px; color:#999">
时间：<?php echo date('Y-m-d H:i:s',$item['add_time']);?>
点击数：<?php echo $item['hits'];?>
</p>
<div class="wzbox">
<?php //echo $item['body'];?>

<?php
$sub_content=$this->s_0->SpLongBody($item['body'],1500,'[nextpage]');
echo $this->s_0->pageBreak($sub_content);
?>

</div>


<div class="jbxz" style="text-align:center;">
<img src="/front/static/images/197.gif" width="16" height="16" align="absmiddle">&nbsp;<a href="<?php echo url('arc','mylist',"level_id={$item['level_id']}");?>" target="_blank"><b><?php echo $item['level_id'];?>级</b></a>&nbsp;
<img src="/front/static/images/103.gif" width="16" height="16" align="absmiddle">&nbsp;
<?php

foreach($tag_attrs as $v){
	$tagid=$object->get_tagid(addslashes($v));
?>
<a href="<?php echo url('attrtag','arc_list',"tagid={$tagid}")?>" target="_blank"><b><?php echo $v;?></b></a>&nbsp;
<?php
}
unset($tag_attrs);
?>
</div>
<div class="jbxz">
<img src="/front/static/images/128.gif" width="16" height="16" align="absmiddle">&nbsp;<b>单词标签:</b>
<?php
foreach($tag_words as $k=>$v){
?>
<a href="<?php echo url('wordtag','arc_list','tag='.urlencode($v['word']),$this->virtual_pjt['PROJECT_URL']);?>" target="_blank"><?php echo $v['word'];?></a>&nbsp;
<?php
}
?>
</div>
<br />
<!--单词开始-->
<div id="wz_jx" style="height:300px;overflow:scroll;">
<br />
<div style="text-align:right;font-weight:bold;color:#09F;">点击<img src="/front/static/images/play.gif" alt="收听单词发音" align="absmiddle"/>收听单词发音&nbsp;&nbsp;</div><br />
<?php

foreach($tag_words as $k=>$v){
	$l=$object->mylevel($v['level_id']);
?>
<div style="width:100%;" class="zc_boxl">
<table width="100%" border="0">
  <tr>
    <td class="td_name">
    <a name="_w_<?php echo $v['index'];?>" id="_w_<?php echo $v['index'];?>" > </a>
    <span class="circle"><?php echo $v['index'];?></span>
    <span class="danci"> <a href="<?php echo url('wordtag','arc_list','tag='.urlencode($v['word']),$this->virtual_pjt['PROJECT_URL']);?>" target="_blank"><?php echo $v['word'];?></a> [<?php echo $v['spell']?>] </span>
    <img src="/front/static/images/play.gif" alt="<?php echo $v['src'];?>" align="absmiddle" style="cursor:pointer;" onClick="qsbdcplayer(this.alt,true,'qsplayer_1');" /> 
    &nbsp;&nbsp;<a href="http://word.qsbdc.com/level_info.php?level_id=<?php echo $v['level_id'];?>" target="_blank">第<?php echo $v['level_id'];?>级</a></td>
    <td class="td_name" align="right"><input type="button" class="button add_word" id="<?php echo $v['id'];?>" value="加入单词本" /></td>
  </tr>
  <tr>
    <td colspan="2" class="zhushi"><?php echo $v['explain'];?></td>
  </tr>
  <tr>
    <td colspan="2"><div class="liju_t">参考例句：</div></td>
  </tr>
  <tr>
    <td colspan="2">
    <div class="liju">
      <ul>
      <?php 
	  $s=explode('||||',$v['sentence']);
	  foreach($s as $w=>$m){
	  ?>
      <li><?php echo $m;?></li>
      <?php
	  }
	  ?>
      </ul>
    </div>
    </td>
  </tr>
</table>
</div>

<?php
}
unset($tag_words);
?>
</div>
<!--单词开始-->

</div>
<div style=" text-align:center">
<a class="button" id="fav" title="<?php echo $item['id'];?>" href="###" style="color:#FFF; text-align:center">收藏</a>
</div>
<div class="context" style="padding-left:5px;">
<?php
$tag=$object->prev_next_arc($item['id']);
?>
<ul>
  <?php
  if(!empty($tag[0])){
  ?>
  <li>上一篇：<a href="<?php echo url('arc','show',"id={$tag[0]['id']}");?>" title="<?php echo $tag[0]['title'];?>"><?php echo $tag[0]['title'];?></a> </li>
  <?php
  }else{
  ?>
  <li>上一篇：没有了 </li>
  <?php
  }
  ?>
  
  <?php
  if(!empty($tag[1])){
  ?>
  <li>下一篇：<a href="<?php echo url('arc','show',"id={$tag[1]['id']}");?>" title="<?php echo $tag[1]['title'];?>"><?php echo $tag[1]['title'];?></a> </li>
  <?php
  }else{
  ?>
  <li>下一篇：没有了 </li>
  <?php
  }
  ?>
  
</ul>
</div>


<?php include(dirname(dirname(__FILE__)).'/footer.inc.php');?>
<script>
$(document).ready(function(){
	var islogin=get_cookie('islogin');
	$('#fav').click(function(){
		if(islogin){
			$.post('<?php echo url('arc','favorite');?>',{'id':$(this).attr('title')},function(data){
					var code=parseInt(data.code);
					if(code<=0){
						alert(data.msg);
						if(code==-2){
							//登陆
							//window.open('http://www.qsbdc.com/');
						}
						return;
					}else{
						alert(data.msg);	
					}
			},'json');	
		}else{
			alert('请先登陆！');	
			//window.open('http://www.qsbdc.com/');
			return;
		}
	});
});

$(function(){ 
    $('#page_break .num li:first').addClass('on'); 
 
    $('#page_break .num li').click(function(){ 
        //隐藏所有页内容 
        $("#page_break div[id^='page_']").hide(); 
 
        //显示当前页内容。 
        if ($(this).hasClass('on')) { 
            $('#page_break #page_' + $(this).text()).show(); 
        } else { 
            $('#page_break .num li').removeClass('on'); 
            $(this).addClass('on'); 
            $('#page_break #page_' + $(this).text()).fadeIn('normal'); 
        } 
    }); 
});
</script>
<div style="display:none;">
<div id="inline_example">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td align="center"><strong>我的单词印象</strong></td>
  </tr>
  <tr>
    <td align="center">
    <input name="type" id="t1" type="radio" value="1" checked /><label for="t1">完全不认识</label>
    <input name="type" id="t2" type="radio" value="2" /><label for="t2">有点印象</label>
    <input name="type" id="t3" type="radio" value="3" /><label for="t3">比较熟悉</label>   
    </td>
  </tr>
  <tr>
    <td>我的理解：<textarea name="myidea" id="myidea" cols="50" rows="4"></textarea></td>
  </tr>
  <tr>
  <td align="center"><input name="sure" id="sure" type="button" value="确定" class="button" /></td>
  </tr>
</table>
</div>
</div>


</body>
</html>